#pragma once

class LogView : public Lockable
{
public:
	// Flag enum
	enum Channel
	{
		Console = 1, 
		File = 2,
		Peer = 4,
		Debug = 8,
	};

	enum CreationFlags
	{
		CreateNewFile = 1,
		OpenExistingFile = 2,
	};

	struct LOGVIEWDESC
	{
		char name[MAX_STRING_LENGTH];
		int channelselection;
		char filename[MAX_STRING_LENGTH];
		int flags;
	};

	LogView(void);
	~LogView(void);

	void Out(char * fmt, ...);
	HRESULT Init(LOGVIEWDESC * desc);
	LOGVIEWDESC & GetDesc(void) { return _Desc; }

protected:
	LOGVIEWDESC _Desc;
	FILE * _File;
};

